<!DOCTYPE html>
<html lang="en">
<head>
    {% include 'public.html' %}
    <title>添加文章</title>
</head>
<body>
<div class="content">

        <input placeholder="主题" id="title" class="form-control" name="title"><br>

        <textarea placeholder="blog内容" class="form-control" rows="10" id="content" roid="content" name="content"></textarea>
    <br>
   <input type="button" class="btn btn-default" value="确定" id="commit">
</div>
<script type="text/javascript">
    $("#commit").click(function () {
          $.post("/save_article/",{title:$("#title").val(),content:$("#content").val()},function(response){
            location.href("/")
    })
    })

</script>
</body>
</html>